<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Iframe Ajax</title>
<script type='text/javascript' src="../system/script/FileUp.js"></script>
<script type='text/javascript'>
	function startCallback() {
	    // make something useful before submit (onStart)
	    return true;
	}

  function completeCallback(response) {
      // make something useful after (onComplete)
      document.getElementById('nr').innerHTML = parseInt(document.getElementById('nr').innerHTML) + 1;
      document.getElementById('r').innerHTML = response;
  }
</script>
</head>
<body>
    <form action="u.aspx" method="post" onsubmit="return FileUp.submit(this, {'onStart' : startCallback, 'onComplete' : completeCallback})">
        <label>Name:</label><input type="text" name="form[name]"/>
        <label>File:</label><input type="file" name="form[file]"/>
        <input type="submit" value="submit" />
    </form>
    <div># of submited forms:<span id="nr">0</span></div>
    <div><pre id="r"></pre></div>
</body>
</html>